import request from '@/plugin/axios/request'

const url = '/v1/shops'

/**
 * 商户列表
 * @param {*} data
 */
export function getShopList(data) {
  return request({
    url,
    method: 'post',
    data: {
      method: 'get.shop.list',
      ...data
    }
  })
}

/**
 * 获取商铺信息
 * @param {Number} shop_id
 * @returns
 */
export function getShopItem(shop_id) {
  return request({
    url,
    method: 'post',
    data: {
      method: 'get.shop.item',
      shop_id
    }
  })
}

/**
 * 审核商户
 * @param {*} data
 */
export function reviewShopItem(data) {
  return request({
    url,
    method: 'post',
    data: {
      method: 'review.shop.item',
      ...data
    }
  })
}
